﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Company.Database.Entities
{
    public class EntityBase
    {
        private int id;
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]//自动递增
        public int Id
        {
            get { return id; }
            set { id = value; }
        }

        private DateTime insertDate = DateTime.Now;
        public DateTime InsertDate
        {
            get { return insertDate; }
            set { insertDate = value; }
        }
    }
}
